package com.bjpowerrnode.streamTest;

import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;

public class AGenerate {
    public static void main(String[] args) {
        List<String> strings = Arrays.asList("aaa", "bbb", "ccc", "", "ddd");
        Stream<String> stringStream = strings.stream().filter(string -> !string.isEmpty());
        System.out.println(stringStream.collect(Collectors.toList()));
    }
}
